package com.cccyy.data;

import java.math.BigDecimal;

public class Str2BigDecimal {
    public static void main(String[] args) {
        BigDecimal amount = new BigDecimal("17.77");
        String str = "10000";
        String s = amount.multiply(new BigDecimal(100)).intValue() + "";
        System.out.println("原有DC01中值转换后为：" + s);
        BigDecimal bigDecimal = new BigDecimal(str);
        System.out.println("str转Bigdecimal的值" + bigDecimal.toString());

        BigDecimal amount2 = new BigDecimal("17.00");
        String s2 = amount2.multiply(new BigDecimal(100)).intValue() + "";
        System.out.println("原有DC01中值转换后为：" + s2);
    }
}
